package com.common.utils;

import com.common.model.HandlerUrl;

/**
 * URI解析
 */
public class UrlUtil {

    public static HandlerUrl handlerUrl(String uri){
        String[] split = uri.replace("/api/", "").split("/");
        HandlerUrl handlerUrl = new HandlerUrl();
        handlerUrl.setController(split[0].trim());
        handlerUrl.setMethod(split[1].trim());
        return handlerUrl;
    }

}
